{{response.files.insert(4, 'https://ajax.googleapis.com/ajax/libs/mootools/1.3.0/mootools-yui-compressed.js')}}
{{response.files.insert(6, URL(request.application,'static','lightface/LightFace.js'))}}
{{response.files.insert(7, URL(request.application,'static','lightface/LightFace.css'))}}
{{extend 'mylayout.html'}}
        <form name="quiz" action="{{=URL(f='showResult')}}" method="post">
            <ol>
                <li><p>You are thirsty and want a drink, what will you do?</p>
                <input type="radio" name="q1" value="a1" checked>Grab a beer with the guys<br/>
                <input type="radio" name="q1" value="a2">Go get some Orange Juice.<br/>
                <input type="radio" name="q1" value="a3">Don't have enough time to get a drink, too much work to do...<br/>
                <input type="radio" name="q1" value="a4">Make someone get you something.<br/>
                </li>
                <li><p>If you discovered that you had accidentally taken a lot of welfare money from honest taxpayers, what would you do to make it up to them?</p>
                <input type="radio" name="q2" value="a1" checked>Drop it from a blimp at the Superbowl<br/>
                <input type="radio" name="q2" value="a2">Ask all the women in town if they`d have sex with you if you gave them their money back<br/>
                <input type="radio" name="q2" value="a3">Give it back? The city is full of immoral fools. No way would you give it back<br/>
                <input type="radio" name="q2" value="a4">Go back in time and stop all those people from being born<br/>
                <input type="radio" name="q2" value="a5">Give it all back in the form of horrible make overs that makes everyone look ugly so you look like the prettiest person on the block<br/>
                </li>
                <li><p>If you lost your son`s birthday party invitations, what would you do to make up for it?</p>
                <input type="radio" name="q3" value="a1" checked>Hijack a parade and lead it to the birthday party<br/>
                <input type="radio" name="q3" value="a2">End the birthday and go meet some friends<br/>
                <input type="radio" name="q3" value="a3">Make your spouse figure it out<br/>
                </li>
                <li><p>Would you degrade yourself if it meant some extra money?</p>
                <input type="radio" name="q4" value="a5" checked>Never. That`s humiliating for who you am<br/>
                <input type="radio" name="q4" value="a5">Sure. You need to buy a new air conditioning anyway<br/>
                </li>
                <li><p>If you were to choose between a free boat and a mystery box, which would you choose?</p>
                <input type="radio" name="q5" value="a1" checked>The boat<br/>
                <input type="radio" name="q5" value="a2">The mystery box. It could even be a boat!<br/>
                </li>
                <li><p>If you were to build a bar in your basement, what would most likely be building it for?</p>
                <input type="radio" name="q6" value="a1" checked>A bar for your friends to pass the time<br/>
                <input type="radio" name="q6" value="a2">To gather people who could test out your new time machine<br/>
                <input type="radio" name="q6" value="a3">You would never build a bar<br/>
                <input type="radio" name="q6" value="a4">To score with chicks<br/>
                </li>
                <li><p>If you could get super powers, what would you use them for?</p>
                <input type="radio" name="q7" value="a1" checked>Use them to get what you want<br/>
                <input type="radio" name="q7" value="a2">Use them to fight crime<br/>
                <input type="radio" name="q7" value="a3">Just sit there and watch<br/>
                </li>
            </ol>
            <input type="submit">
        </form>
{{if character:}}
<script>
    function PublishResultFunction() {
        box = new LightFace({
            title: 'Information',
            width: 480,
            height: 150,
            content: '{{=DIV(DIV(IMG(_src=character['pic']), _id="result_picture"), DIV(P("You already did the quiz ", B("%s!" % character['name']), BR(), BR(), "Wanna do it again?"), _id="result_text"), _id="result_wrapper")}}',
            buttons:[
                {
                    title: 'Yes',
                    event: function() {this.close();},
                    color: 'green',
                },
                {
                    title: 'No',
                    event: function() {top.location.href = "http://apps.facebook.com/amazing_quiz{{=URL('otherOffers')}}";},
                }
            ]
        });
        box.open();
    }
    $(document).ready(function(){
        PublishResultFunction();
    });
</script>
{{pass}}
